Skip to content

Fix next changelog workflow#808

Merged
vikrantpuppala merged 7 commits into
mainfrom
fix-next-changelog
Apr 25, 2025
Merged

Fix next changelog workflow#808
vikrantpuppala merged 7 commits into
mainfrom
fix-next-changelog

Conversation

@vikrantpuppala
Copy link
Copy Markdown
Collaborator

@vikrantpuppala vikrantpuppala commented Apr 25, 2025

Description

Fixes issue with next changelog when there are special chars in PR desc or changed files

Testing

Link with no changelog: https://github.com/databricks/databricks-jdbc-dev/actions/runs/14658736565
Link with comment added to skip: https://github.com/databricks/databricks-jdbc-dev/actions/runs/14658885212

Additional Notes to the Reviewer

NO_CHANGELOG=true

@github-actions
Copy link
Copy Markdown

Please ensure that the `NEXT_CHANGELOG.md` file is updated with any relevant changes.  
If this is not necessary for your PR, include this in the PR body:

```
NO_CHANGELOG=true
```

and rerun the workflow.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes an issue with the next changelog workflow when special characters appear in the PR description or in the list of changed files. The changes include switching to using the GitHub API (via the gh CLI) to fetch changed files and PR messages, sanitizing the output to avoid code injection issues, and updating the logic to post or remove PR comments based on whether NEXT_CHANGELOG.md is modified or a NO_CHANGELOG flag is set.

Comment thread .github/workflows/checkNextChangelog.yml
@madhav-db
Copy link
Copy Markdown
Collaborator

This check should pass when running on this PR, right? Seems like it still fails.

@vikrantpuppala
Copy link
Copy Markdown
Collaborator Author

the check uses pull_request_target so it still fails on this PR, next PRs would use the new workflow @madhav-db

@samikshya-db samikshya-db self-requested a review April 25, 2025 10:24
@vikrantpuppala vikrantpuppala merged commit bea0564 into databricks:main Apr 25, 2025
15 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants